Skip to content

Fixed types of filter enums#68

Merged
tkrebes merged 1 commit intomainfrom
fix-filter-enum-types
Sep 24, 2025
Merged

Fixed types of filter enums#68
tkrebes merged 1 commit intomainfrom
fix-filter-enum-types

Conversation

@tkrebes
Copy link
Copy Markdown
Owner

@tkrebes tkrebes commented Sep 23, 2025

What does this Pull Request accomplish?

This fixes the service_type, connects_to_bus_type and provides_bus_type filter options by specifying them as UnsignedIntProperty instead of IntProperty.

Why should this Pull Request be merged?

This PR address #67

The Filter object uses NISysCfgSetFilterPropertyWithType to set values. This requires knowledge of the backing type to retrieve the value.

What testing has been done?

Ran unit tests; all tests passed.

Checked that PXI devices could be found with

import nisyscfg
session = nisyscfg.Session()
hw_filter = session.create_filter()
hw_filter.connects_to_bus_type = nisyscfg.enums.BusType.PCI_PXI
hw = list(session.find_hardware(hw_filter))
print(hw)

@tkrebes tkrebes linked an issue Sep 23, 2025 that may be closed by this pull request
@tkrebes tkrebes marked this pull request as ready for review September 24, 2025 16:48
@tkrebes tkrebes merged commit 3478cd8 into main Sep 24, 2025
12 checks passed
@tkrebes tkrebes deleted the fix-filter-enum-types branch September 24, 2025 16:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Filtering on connects_to_bus_type is not working

1 participant